home *** CD-ROM | disk | FTP | other *** search
/ MacHack 1994 / MacHack 1994.toast / MacHack™ 1987-1994 / MacHack™ '92 / Hacks ’92 / ARAStatus ƒ / IconSuite.h < prev    next >
Encoding:
C/C++ Source or Header  |  1992-06-19  |  3.2 KB  |  77 lines  |  [TEXT/KAHL]

  1. /*
  2.     IconSuite.h
  3.  */
  4.  
  5. #pragma once
  6.  
  7. #ifndef __TYPES__
  8. #include <Types.h>
  9. #endif
  10.  
  11. #define svMini1Bit 0x00010000
  12. #define svMini4Bit 0x00020000
  13. #define svMini8Bit 0x00040000
  14. #define svAllMiniData 0x00ff0000
  15.  
  16. enum {
  17.     largeIcon1 = 0,
  18.     largeIcon4,
  19.     largeIcon8,
  20.     smallIcon1,
  21.     smallIcon4,
  22.     smallIcon8,
  23.     miniIcon1,
  24.     miniIcon4,
  25.     miniIcon8
  26. };
  27.  
  28. #define IconSpace (miniIcon8 + 1)
  29.  
  30. struct IconSuite {
  31.     unsigned short type;
  32.     unsigned short label;
  33.     Handle table[IconSpace];
  34. };
  35.  
  36. typedef struct IconSuite IconSuite;
  37.  
  38. /* C Glue */
  39. pascal OSErr PlotIconID(const Rect *theRect, short align, short  transform, short theResID)
  40.      = {0x303C, 0x0500, 0xABC9};
  41. pascal OSErr NewIconSuite(Handle *theIconSuite) = {0x303C, 0x0207, 0xABC9};
  42. pascal OSErr AddIconToSuite(Handle theIconData,Handle theSuite,ResType theType)= {0x303C, 0x0608, 0xABC9};
  43. pascal OSErr GetIconFromSuite(Handle *theIconData,Handle theSuite,ResType theType)= {0x303C, 0x0609, 0xABC9};
  44. pascal OSErr ForEachIconDo(Handle theSuite,long selector,ProcPtr action,void *yourDataPtr)
  45.     = {0x303C, 0x080A, 0xABC9};
  46. pascal OSErr GetIconSuite(Handle *theIconSuite,short theResID,long selector)= {0x303C, 0x0501, 0xABC9};    
  47. pascal OSErr DisposeIconSuite(Handle theIconSuite,Boolean disposeData)= {0x303C, 0x0302, 0xABC9};
  48. pascal OSErr PlotIconSuite(const Rect *theRect,short align,short transform,Handle theIconSuite)
  49.     = {0x303C, 0x0603, 0xABC9};
  50. pascal OSErr MakeIconCache(Handle *theHandle,ProcPtr makeIcon,void *yourDataPtr)= {0x303C, 0x0604, 0xABC9};
  51. pascal OSErr LoadIconCache(const Rect *theRect,short align,short transform,Handle theIconCache)
  52.     = {0x303C, 0x0606, 0xABC9};
  53. pascal OSErr GetLabel(short labelNumber,RGBColor *labelColor,Str255 labelString)= {0x303c, 0x050B, 0xABC9};
  54. pascal Boolean PtInIconID(Point testPt,Rect *iconRect,short alignment,short iconID)= {0x303c, 0x060D, 0xABC9};
  55. pascal Boolean PtInIconSuite(Point testPt,Rect *iconRect,short alignment,Handle theIconSuite)
  56.     = {0x303c, 0x070E, 0xABC9};
  57. pascal Boolean RectInIconID(Rect *testRect,Rect *iconRect,short alignment,short iconID)
  58.     = {0x303c, 0x0610, 0xABC9};
  59. pascal Boolean RectInIconSuite(Rect *testRect,Rect *iconRect,short alignment,Handle theIconSuite)
  60.     = {0x303c, 0x0711, 0xABC9};
  61. pascal OSErr IconIDToRgn(RgnHandle theRgn,Rect *iconRect,short alignment,short iconID)
  62.     = {0x303c, 0x0613, 0xABC9};
  63. pascal OSErr IconSuiteToRgn(RgnHandle theRgn,Rect *iconRect,short alignment,Handle theIconSuite)
  64.     = {0x303c, 0x0714, 0xABC9};
  65. pascal OSErr SetSuiteLabel(Handle theSuite, short theLabel)= {0x303C, 0x0316, 0xABC9};
  66. pascal short GetSuiteLabel(Handle theSuite)= {0x303C, 0x0217, 0xABC9};    
  67. pascal OSErr GetIconCacheData(Handle theCache, void **theData)= {0x303C, 0x0419, 0xABC9};    
  68. pascal OSErr SetIconCacheData(Handle theCache, void *theData)= {0x303C, 0x041A, 0xABC9};    
  69. pascal OSErr GetIconCacheProc(Handle theCache, ProcPtr *theProc)= {0x303C, 0x041B, 0xABC9};    
  70. pascal OSErr SetIconCacheProc(Handle theCache, ProcPtr theProc)= {0x303C, 0x041C, 0xABC9};
  71. pascal OSErr PlotSICNHandle(const Rect *theRect,short align,short transform,Handle theSICN)
  72.     = {0x303C, 0x061E, 0xABC9};
  73. pascal OSErr PlotCIconHandle(const Rect *theRect,short align,short transform,CIconHandle theCIcon)
  74.     = {0x303C, 0x061F, 0xABC9};
  75. pascal OSErr SetLabel(short labelNumber, const RGBColor *, ConstStr255Param)
  76.     = {0x303C, 0x050C, 0xABC9};
  77.